package org.dingyom.basics.util;

public class AjaxResult {
    private boolean success = true;//操作 成功 默认是成功的
    private String message = "操作成功";

    private Object data;//返回数据

    public static  AjaxResult me(){
        return new AjaxResult();
    }

    public boolean isSuccess() {
        return success;
    }

    public AjaxResult setSuccess(boolean success) {
        this.success = success;
        return this;//谁调用我 就返回谁
    }

    public String getMessage() {
        return message;
    }

    public AjaxResult setMessage(String message) {
        this.message = message;
        return this;
    }

    public Object getData() {
        return data;
    }

    public AjaxResult setData(Object data) {
        this.data = data;
        return this;
    }
}
